import Vue from 'vue'
import Router from 'vue-router'

import home from '../components/home'
import jbxx from '../components/jbxx'
import rygk from '../components/rygk'
import bdzy from '../components/bdzy'
import xhjc from '../components/xxjc'
import hwxj from '../components/hwxj'
import dwhc from '../components/dwhc'
import yyyb from '../components/yqyb'
import shipinjiankong from '../components/shipinjiankong'
import yingshiyun from '../components/yingshiyun'
import demo from '../components/demo'
import sljy from '../components/sljy'
import slbh from '../components/slbh'
import transit from '../components/transit'
import Map_monitoring from '../components/Map_monitoring' // 地图监测
import Monitoring from '../components/Monitoring' // 监控画面
import Statistics from '../components/Statistics' // 统计分析

Vue.use(Router)

export default new Router({
  linkActiveClass: 'link-active',
  mode: 'history',
  routes: [
    {path: '/', redirect: {name: 'transit'}},
    {
      path: "/transit",
      name: "transit",
      component: transit
    },
    {
      path: '/home', name: 'home', component: home, redirect: {name: 'jbxx'}, children: [
        {path: '/home/jbxx', name: 'jbxx', component: jbxx},
        {path: '/home/rygk', name: 'rygk', component: rygk},
        {path: '/home/bdzy', name: 'bdzy', component: bdzy},
        {path: '/home/xhjc', name: 'xhjc', component: xhjc},
        {path: '/home/hwxj', name: 'hwxj', component: hwxj},
        {path: '/home/dwhc', name: 'dwhc', component: dwhc},
        {path: '/home/yyyb', name: 'yyyb', component: yyyb},
        {path: '/home/ysy', name: 'ysy', component: yingshiyun},
        {path: '/home/sljy', name: 'sljy', component: sljy},
        {path: '/home/slbh', name: 'slbh', component: slbh},
        {path: '/home/shipinjiankong', name: 'shipinjiankong', component: shipinjiankong},
        {path: '/home/Map_monitoring', name: 'Map_monitoring', component: Map_monitoring},
        {path: '/home/Monitoring', name: 'Monitoring', component: Monitoring},
        {path: '/home/Statistics', name: 'Statistics', component: Statistics},
      ]
    },
    {path: '/demo', name: 'demo', component: demo},
  ]
})
